export default {
  props: {
    value: String,
    options: Object
  },
  render(h) {
    var options = Object.assign(
      {
        fit: 'contain',
        shape: 'square',
        size: 'large',
        defaultImage: ''
      },
      this.options
    )
    const { shape, size, fit, defaultImage } = options
    return h('el-avatar', {
      props: {
        src: this.value || defaultImage,
        fit: fit,
        size: size,
        shape: shape
      }
    })
  }
}
